<?php include_once './application/views/sys_admin/common/header.php';  ?>
<div class=" definewidth m20" >
		<form action="" method="get" class="form-inline definewidth m20" id="form5" name="form5">
			用户名：<input type="text" id="username" name="username" style="width: 100px;"  value="<?php echo $parms['username'];?>" />
  			手机号：<input type="text" id="phone" name="phone" style="width:100px;"  value="<?php echo $parms['phone'];?>" />
  			Email：<input type="text" id="email" name="email" value="<?php echo $parms['email'];?>" />
  			真实姓名：<input type="text" id="realname" name="realname" style="width: 100px;"  value="<?php echo $parms['realname'];?>" />
  			注册时间：<input type="text" id="add_time" name="add_time" style="width:100px;" value="<?php echo $add_time;?>"  onfocus="WdatePicker()" class="Wdate" />
  			<button type="button" class="btn btn-primary"  onclick="this.form.submit();" >查询</button>
  			<button type="button" class="btn btn-success"  onclick="sendAll();" >批量发送</button>
  			<button type="button" class="btn btn-success" onclick="href('/sys_admin/user/userListAllExcel')">导出数据</button>
  		</form>
		<table class="table table-bordered table-hover definewidth m10">
			<thead>
			    <tr>
				  	<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><input type="checkbox" value="0" onclick="checkAll(this)" id="checkbox_handle"></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>序号</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>会员名</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>会员等级</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>累计充值金额</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>累计投标数量</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>累计投标金额</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>账户余额</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>邮箱</strong></td> 
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>手机</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>介绍人</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>注册时间</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>最后登录时间</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>状态</strong></td>
					<td height="35" align="center" valign="middle" bgcolor="#F1F1F1"><strong>操作</strong></td>
				  </tr>
			   </thead>
			   <?php foreach($user_list as $info){?>
			  <tr overstyle="on" id="list_<?php echo $info['user_id']?>">
			  	<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><input type="checkbox" value="<?php echo $info['user_id'];?>" onclick="checkon(this)" id="checkbox2" name="checkbox"></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo $info['user_id'];?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><a href="javascript:showUser(<?php echo $info['user_id'];?>);"><?php echo $info['username'];?></a></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF">
								<?php if(isset($info['vip_pic']) && !empty($info['vip_pic'])){?>
					<img src="/static/credit/<?php echo $info['vip_pic']?>"/>
				<?php }else echo "无";?>	
				</td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo number_format($info['recharge_money'],2);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo number_format($info['tender_count']);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo number_format($info['tender_money'],2);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo number_format($info['use_money'],2);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo $info['email'];?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo $info['phone'];?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo $info['invite_uname'];?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo date('Y-m-d H:i',$info['add_time']);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo date('Y-m-d H:i',$info['lasttime']);?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF"><?php echo $userFstatus[$info['fstatus']];?></td>
				<td height="35" align="center" valign="middle" bgcolor="#FFFFFF">
				<a href="javascript:;" onclick="doSend(<?php echo $info['user_id'];?>);">发送</a> 
				<a href="/sys_admin/user/edit/<?php echo $info['user_id'];?>">修改</a> 
				</td>
			  </tr>
			  <?php }?>
			  	<tr>
			  	<td colspan="8"  class="invbd_page"><?php echo $this->pagination->create_links();?></td>
			  	</tr>
		</table>
</div>
<div id="dialog" title="用户信息" style="display:none">
	<div id="view_response"></div>
</div>

<div id="senddialog" title="发送信息" style="display:none">
	<div id="view_send_response"></div>
</div>
